
    /**  
    * @Title: PortalStatemachFieldAuthController.java
    * @Package com.efast.cafe.portal.controller.statemach
    * @Description: TODO(用一句话描述该文件做什么)
    * @author Administrator
    * @date 2019年3月20日
    * @version V1.0  
    */
    
package com.efast.cafe.portal.controller.statemach;

import java.util.Arrays;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import com.efast.cafe.commponent.statemach.bean.PortalStatemachFieldAuth;
import com.efast.cafe.commponent.statemach.bean.StatemachFieldAuthQueryBean;
import com.efast.cafe.framework.bean.ResultBean;
import com.efast.cafe.portal.bean.statemach.PortalStatemachFieldAuthSaveBean;
import com.efast.cafe.portal.service.statemach.IPortalStatemachFieldAuthService;

@Controller
@RequestMapping("/statemach")
public class PortalStatemachFieldAuthController {
	
	@Autowired
	private IPortalStatemachFieldAuthService portalStatemachFieldAuthService;

	@RequestMapping(value = "/fieldAuth/query",method=RequestMethod.POST)
	public @ResponseBody ResultBean queryFieldAuth(
			@RequestBody StatemachFieldAuthQueryBean queryBean){
		ResultBean res = new ResultBean(true);
		res.setObject(portalStatemachFieldAuthService.queryStatemachAuth(queryBean));
		return res;
	}
	
	@RequestMapping(value = "/fieldAuth/save",method=RequestMethod.POST)
	public @ResponseBody ResultBean saveFieldAuth(@RequestBody PortalStatemachFieldAuthSaveBean auths){
		ResultBean res = new ResultBean(true);
		portalStatemachFieldAuthService.saveStatemachFieldAuth(auths);
		return res;
	}
}
